<?php
	
	// dbdelete($con,$table,$where=null)
	//权限管理
	authonity($con);
	
	
	$id = $_GET['id'];

	$mid = $_GET['mid'];

	$aid = $_GET['aid'];
	
	$del = dbdelete($con,'products',"id=$id");
	if($del){
		echo "<script>alert('删除成功');location.href='index.php?m=admin&c=product&mid={$mid}&aid=$aid'</script>";
	}else{
		echo "<script>alert('删除失败');location.href='index.php?n=admin&c=product&mid={$mid}&aid=$aid'</script>";
	}


	
	
	
?>